/**
 * Created by Administrator on 2017/10/27
 */
import { WeaTools } from 'ecCom';

export const getWfAgentList = params => {
    return WeaTools.callApi('/api/workflow/agent/getList', 'POST', params);
};
//新建代理
export const getWfNewAgent = params => {
    return WeaTools.callApi('/api/workflow/agent/getAddAgentInfo','POST',params);
};
//高级查询
export const getWfHighSearch = params => {
    return WeaTools.callApi('/api/workflow/agent/getSearchCondition', 'POST', params);
};
//编辑代理
export const getWfEditAgent = params => {
    return WeaTools.callApi('/api/workflow/agent/getEditAgentInfo', 'POST', params);
};
//批量编辑打开
export const getWfBatchEdit = () => {
    return WeaTools.callApi('/api/workflow/agent/getBatchEditInfo', 'POST');
};
//新建、编辑、批量编辑保存时校验是否存在重复
export const verifyAgentOverlap = params => {
    return WeaTools.callApi('/api/workflow/agent/verifyAgentOverlap', 'POST', params);
};
//新建保存
export const addAgentSave = params => {
    return WeaTools.callApi('/api/workflow/agent/addAgentSave', 'POST', params);
};
//编辑保存
export const editAgentSave = params => {
    return WeaTools.callApi('/api/workflow/agent/editAgentSave', 'POST', params);
};
//批量编辑保存
export const batchEditAgentSave = params => {
    return WeaTools.callApi('/api/workflow/agent/saveBatchEditInfo', 'POST', params);
};

//点击收回代理的提示信息
export const takeBackPromptMsg = params => {
    return WeaTools.callApi('/api/workflow/agent/takeBackPromptMsg', 'POST', params);
};
//确认收回代理
export const takeBackAgent = params => {
    return WeaTools.callApi('/api/workflow/agent/takeBackAgent', 'POST', params);
};
// 代理条件打开
export const agentConditionOpen = params => {
    return WeaTools.callApi('/api/workflow/agent/getEditAgentConditionInfo', 'POST', params);
};
// 代理条件保存
export const agentConditionSave = params => {
    return WeaTools.callApi('/api/workflow/agent/editAgentConditionSave', 'POST', params);
};
//删除模板
export const deleteAgentTemplate = params => {
    return WeaTools.callApi('/api/workflow/agent/deleteAgentTemplate', 'POST', params);
};
//保存模板
export const saveAgentTemplate = params => {
    return WeaTools.callApi('/api/workflow/agent/saveAgentTemplate', 'POST', params);
};
//编辑，另存为打开
export const editAndSaveOther = params => {
    return WeaTools.callApi('/api/workflow/agent/getAgentDetail', 'POST', params);
};

//编辑，另存为保存
export const editAndSaveOtherSave = params => {
    return WeaTools.callApi('/api/workflow/agent/saveAgentDetail', 'POST', params);
};
//模板管理列表
export const manageList = params => {
    return WeaTools.callApi('/api/workflow/agent/agentTemplateList', 'POST', params);
};
//模板管理高级查询
export const manageHighSearch = params => {
    return WeaTools.callApi('/api/workflow/agent/agentTemplateCondition', 'POST', params);
};
